-
Notifications
You must be signed in to change notification settings - Fork 41
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Remember referenced repositories as system repositories instead of user #512
Conversation
I see that org.eclipse.equinox.internal.p2.updatechecker.UpdateChecker.checkForUpdates(String, IQuery) calls org.eclipse.equinox.internal.p2.updatechecker.UpdateChecker.getAvailableRepositories() which calls org.eclipse.equinox.p2.repository.IRepositoryManager.getKnownRepositories(int) with argument org.eclipse.equinox.p2.repository.IRepositoryManager.REPOSITORIES_ALL. As such, is accurate to conclude that not showing the repositories to the user actually has no impact on how Check for Updates will behave after the repo is added (discovered), regardless of whether the repo is marked system or not? If so, this change does not actually address the "Even worse..." aspect described in the first comment. If not, what am I overlooking? It's rather disconcerting that there are repositories that will be contacted and used but you can't see , remove, nor disable them.... |
I can't tell much about If one wants to see "everything" I'm sure the UI can be enhanced to support that use-case but this really focus on the part that I don't get new user repositories as a side effect of performing a check for updates. |
If you checked in the debugger then I’m reassured and this looks like a nice change. I had the same idea about a check box to show system repositories; it would help debug. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
In case someone/something relies on the old behavior, which I doubt, one might use a system property to specify true versus the default of false.
If such thing is required I think it should (again) be an UI thing so when I add the site I can select to also add references and maybe select what I want to have added. |
It’s not required. It’s just a thought. |
77e4fb3
to
3199f3f
Compare
Currently there is a quite surprising behavior, that if a user adds an updatesite that contains a referenced repository, that after an update-check additional repositories are visible. Even worse these are now used additionally to check for updates and if they contain other references these are also added and so on. This can result not only in a long list of sites the user never has added and has no clue where they are coming from but even pulling in unwanted or conflicting updates. This now distinguishes two cases: 1) A repository is discovered by the RepositoryAction it is handled as a user added repository and becomes visible 2) A repository is discovered by a reference in that case it is handled as a system repository and not becomes visible that way the list of user visible repositories stay clean from referenced repositories and unexpected side effects on update checks.
I now added |
Kudos for investing your time on these improvements! 🏅 |
No problem, this was an issue for too long now and seem to regularly cause confusions. |
Currently there is a quite surprising behavior, that if a user adds an
updatesite that contains a referenced repository, that after an
update-check additional repositories are visible. Even worse these are
now used additionally to check for updates and if they contain other
references these are also added and so on. This can result not only in a
long list of sites the user never has added and has no clue where they
are coming from but even pulling in unwanted or conflicting updates.
Before this change
Here is an example with the m2e update site (
https://download.eclipse.org/technology/m2e/snapshots/latest/
):In the first step there is only this single site:
Now I go to
Help > Check For Updates
and after this completes I end up with the following list (10 sites):Now I repeat and perform
Help > Check For Updates
and after this completes I end up with the following list (12 sites):After this changes
This now distinguishes two cases:
user added repository and becomes visible
as a system repository and not becomes visible
that way the list of user visible repositories stay clean from
referenced repositories and unexpected side effects on update checks.
FYI @merks @HannesWell @jonahgraham